<%def name="table_for_dict(d)">
<table>
% for k in d or {}:
<tr>
    <td>${k} = </td>
    <td>${d[k]}</td>
</tr>
% endfor
</table>
</%def>

${exc}

<h2>Params</h2>
${self.table_for_dict(req.params)}

% if req.session:
<h2>Session</h2>
${self.table_for_dict(req.session)}
% endif

% if req.cookie:
<h2>Cookies</h2>
${self.table_for_dict(req.cookie)}
% endif

<h2>Environment</h2>
${self.table_for_dict(req.env)}

